home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 2994 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  961 b 

  1. Path: news.erg.cuhk.hk!ykwu2
  2. From: ykwu2@ie.cuhk.hk (wu yau kin)
  3. Newsgroups: comp.lang.c
  4. Subject: Some Questions about DLL
  5. Date: 25 Jan 1996 09:59:41 GMT
  6. Organization: Engineering Faculty CUHK
  7. Message-ID: <4e7kad$sfo@eng_ser1.erg.cuhk.hk>
  8. NNTP-Posting-Host: ieug23.ie.cuhk.hk
  9. X-Newsreader: NN version 6.5.0 #7 (NOV)
  10.  
  11.     I am writing program in delphi (a pascal language) which will call c/c++ modules in Windows environment.  I want to know how to write DLL in C/C++.
  12.  
  13.     What is needed in the source code in c/c++?  (I am using BC45 and I know there is something called DEF file but I don't know how to use it)
  14.  
  15.     For example,
  16.  
  17.     int sum(int x,int y)
  18.     {
  19.       return(x+y);
  20.     }
  21.  
  22.     is a function in c/c++ code which will be placed in DLL.  What is the declaration and definition in order to make it into DLL and be called by other program.
  23.  
  24.     Thank you!
  25.  
  26. Akin
  27.  
  28. --
  29. ----------------------------
  30. Never trouble troubles
  31. http://www.ie.cuhk.hk/~ykwu2
  32. ----------------------------
  33.